package samples.d3.image 
{
	import flash.display.Bitmap;
	import flash.display.BitmapData;
	import flash.events.MouseEvent;
	import flash.geom.Matrix;
	import flash.geom.Vector3D;
	import flash.utils.setTimeout;
	import graphics.image.Outline;
	import samples.BaseSample;
	import shapes.particles.Renderer3D;
	import shapes.particles.Viewport;
	
	/**
	 * @author Nicolas Barradeau
	 * http://en.nicoptere.net
	 */
	public class Image0 extends BaseSample
	{
		
		//[Embed(source = '../../../../lib/penguins.jpg')]private var imageSrc:Class;
		[Embed(source = '../../../../lib/outline.png')]private var imageSrc:Class;
		//[Embed(source = '../../../../lib/wheel_HSL.png')]private var imageSrc:Class;
		//[Embed(source = '../../../../lib/fruit0.jpg')]private var imageSrc:Class;
		//[Embed(source = '../../../../lib/fruit1.jpg')]private var imageSrc:Class;
		
		private var image:Bitmap;
		private var bd:BitmapData;
		
		
		public function Image0() 
		{
			image = new imageSrc();
			
			var w:int = image.width;
			var h:int = image.height;
			
			var scale:Number = 1;
			bd = new BitmapData( w * scale, h * scale, true, 0 );
			bd.draw( image, new Matrix( scale, 0, 0, scale ) );
			Outline.process( bd )
			addChild( new Bitmap( Outline.bitmapData ) );
			
		}
	}

}